<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>秀视频后台管理平台-背景音乐</title>
<meta name="keywords" content="秀视频后台管理平台">
<meta name="description" content="秀视频后台管理平台欢迎您的到来">
<link rel="shortcut icon" href="favicon.ico">
<link href="../css/github-gist.css" rel="stylesheet">
<link href="../css/bootstrap.min.css" rel="stylesheet">
<link href="../css/font-awesome.css" rel="stylesheet">
<link href="../css/plugins/bootstrap-table/bootstrap-table.min.css"
	rel="stylesheet">
<link href="../css/animate.css" rel="stylesheet">
<link href="../css/style.css" rel="stylesheet">
<link href="../css/index.css" rel="stylesheet">
<link href="../css/base.css" rel="stylesheet">
<link href="../css/fakeLoader.css" rel="stylesheet">
<link href="../css/plugins/sweetalert/sweetalert.css" rel="stylesheet">

<style>
.news_infos span {
	font-size: 13px;
}

#picker {
	display: none;
}
</style>
</head>

<body class="white-bg" style="opacity: 0">

	<div class="col-sm-6">
		<div class="ibox float-e-margins">
			<div class="ibox-title">
				<h5>基本</h5>
				<div class="ibox-tools">
					<a class="collapse-link"> <i class="fa fa-chevron-up"></i>
					</a> <a class="dropdown-toggle" data-toggle="dropdown"
						href="table_basic.html#"> <i class="fa fa-wrench"></i>
					</a>
					<ul class="dropdown-menu dropdown-user">
						<li><a href="table_basic.html#">选项1</a></li>
						<li><a href="table_basic.html#">选项2</a></li>
					</ul>
					<a class="close-link"> <i class="fa fa-times"></i>
					</a>
				</div>
			</div>
			<div class="ibox-content">

				<table class="table">
					<thead>
						<tr>
							<th>#</th>
							<th>角色名称</th>
							<th>操作1</th>
							<th>操作2</th>
						</tr>
					</thead>
					<tbody id="tb">
					</tbody>
				</table>

			</div>
		</div>
	</div>




	<script type="text/javascript" src="../js/jquery.min.js"></script>
	<script type="text/javascript" src="../js/webuploader.js"></script>
	<script type="text/javascript" src="../js/webuploader.js"></script>
	<!-- 全局js -->
	<script src="../js/jquery.min.js"></script>
	<script src="../js/highlight.pack.js"></script>
	<script>
		hljs.initHighlightingOnLoad();
	</script>
	<script src="../js/bootstrap.min.js"></script>
	<!-- 自定义js -->
	<script src="../js/plugins/sweetalert/sweetalert.min.js"></script>
	<script src="../js/contabs.js"></script>
	<script src="../js/fakeLoader.min.js"></script>
	<!-- Bootstrap table -->
	<script src="../js/plugins/bootstrap-table/bootstrap-table.min.js"></script>
	<script
		src="../js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script>

	<script
		src="../js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script>
	<script src="../js/bgm/bgmTable.js"></script>
	<script src="../js/content.js"></script>
	<script src="../js/plugins/sweetalert/sweetalert.min.js"></script>
	<script src="../js/fakeLoader.min.js"></script>
	<script src="../js/plugins/validate/jquery.validate.min.js"></script>
	<script src="../js/plugins/validate/messages_zh.min.js"></script>
	<script type="text/javascript">
		$(document)
				.ready(
						function() {
							//初始化表单
							$
									.ajax({
										url : "../../role/queryAllRole",
										type : "post",
										success : function(res) {
											console.log("result data");
											console.log(res.data);
											//遍历输出到表单上
											for (var i = 0; i < res.data.length; i++) {
												$("#tb")
														.append(
																"<tr><td>"
																		+ res.data[i].id
																		+ "</td><td>"
																		+ res.data[i].name
																		+ "</td><td>"
																		+ "<a href='../../static/page/adminToRole_management.html?id="
																		+ res.data[i].id
																		+ "'><button type='button' class='btn btn-default' >分配角色</button></a>"
																		+ "</td><td><a href='../../static/page/adminToRole_management.html?id="
																		+ res.data[i].id
																		+ "'><a href='../../static/page/show_adminToRole.html?id="+res.data[i].id+"'><button type='button' class='btn btn-default' >查看用户</button></a></td></tr>");//追加新的元素到
											}
										}
									})
						});
	</script>

	<!-- Bootstrap table -->
	<script src="../js/plugins/bootstrap-table/bootstrap-table.min.js"></script>
	<script
		src="../js/plugins/bootstrap-table/bootstrap-table-mobile.min.js"></script>
	<script
		src="../js/plugins/bootstrap-table/locale/bootstrap-table-zh-CN.min.js"></script>

</body>
</html>
